const commonRoutes = [
  {
    path: "labor", // 渠道劳务费结算
    component: () => import("@/views/settlement/labor")
  },
  {
    path: "labor/detail", // 详情
    component: () => import("@/views/settlement/labor/detail")
  },
  {
    path: "billing", // 费用账单
    component: () => import("@/views/settlement/billing")
  },
  {
    path: "billing/billingDetail", // 详情
    component: () => import("@/views/settlement/billing/billingDetail")
  },
  {
    path: "record", // 客户回款记录
    component: () => import("@/views/settlement/record")
  },
  {
    path: "record/details", // 详情
    component: () => import("@/views/settlement/record/details")
  }
];

export const SettlementRouter = {
  path: "/settlementAdmin", // 客户结算
  component: () => import("@/layout/adminNew"),
  children: [].concat(commonRoutes, [
    {
      path: "kehumingxibiao", // 客户明细表
      component: () => import("@/views/settlement/customers/index_new")
    },
    {
      path: "kehumingxibiao/customerDetail", // 客户明细表
      component: () => import("@/views/settlement/customers/customerDetail_new")
    },
    {
      path: "fuwufeixiang", // 服务费项
      component: () => import("@/views/settlement/customers/fuwufeixiang")
    },
    {
      path: "customers", // 客户明细表
      component: () => import("@/views/settlement/customers")
    },
    {
      path: "customers/customerDetail", // 详情
      component: () => import("@/views/settlement/customers/customerDetail")
    },
    {
      path: "socialSecurityPlan",
      component: () => import("@/views/settlement/socialSecurityPlan")
    },
    {
      path: "socialSecurityPlan/upLoad",
      component: () => import("@/views/settlement/socialSecurityPlan/upLoad")
    }
  ])
};

export const SettlementAdminRouter = {
  path: "/settlementAdmin",
  component: () => import("@/layout/adminNew"),
  meta: {
    title: "客户结算"
  },
  children: [].concat(commonRoutes, [])
};
